# build info
set(CMAKE_INSTALL_PREFIX ${CMAKE_SOURCE_DIR}/install)

if(CMAKE_HOST_SYSTEM_NAME STREQUAL "Windows")
    # windows PATH example
    # set PATH=%PATH%;)
    #       D:/Development/Envs/QtEnv/6.7.0/msvc2019_64/bin;
    #       D:/Development/Envs/OpenCV460/Binary/x64/vc16/bin;
    #       D:/Development/Envs/openvino_2024.6/runtime/3rdparty/tbb/bin;
    #       D:/Development/Envs/openvino_2024.6/runtime/bin/intel64/Debug;
    #       D:/Development/Envs/openvino_2024.6/runtime/bin/intel64/Release;
    # QT
    set(QT_DIR D:/Envs/Qt6/6.6.2/msvc2019_64/lib/cmake)
    if (CMAKE_BUILD_TYPE STREQUAL "Debug")
        set(OpenCV_DIR "D:/Envs/OnnxDev/opencv/OpenCVBinDebug/x64/vc17/lib")
    else()
        set(OpenCV_DIR "D:/Envs/OnnxDev/opencv/OpenCVBinRelease/x64/vc17/lib")
    endif ()

    set(XTENSOR_USE_XSIMD ON)
    set(xtl_DIR D:/Envs/OnnxDev/xtensor/xtlBin/share/cmake/xtl)
    set(xsimd_DIR D:/Envs/OnnxDev/xtensor/xsimdBin/share/cmake/xsimd)
    set(xtensor_DIR D:/Envs/OnnxDev/xtensor/xtensorBin/share/cmake/xtensor)

    set(onnxruntime_DIR D:/Envs/OnnxDev/Microsoft.ML.OnnxRuntime.OpenVino.1.20.0)
    set(onnxruntime_INCLUDE ${onnxruntime_DIR}/include)
    set(onnxruntime_LIBS
        ${onnxruntime_DIR}/lib/onnxruntime.lib
    )
else()
    # use rpath
    # set rpath as bin directory
    set(CMAKE_SKIP_BUILD_RPATH FALSE)
    set(CMAKE_INSTALL_RPATH ${ORIGIN})
    # set(CMAKE_BUILD_WITH_INSTALL_RPATH TRUE)
    # set(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE)

    # qt
    set(QT_DIR /home/tacom/QtEnv/6.7.2/gcc_64/lib/cmake)

    # opencv
    set(OpenCV_DIR /media/tacom/fd1834d9-91ec-45dc-908b-eed1b326caaa/Envs/onnxruntime-openvino/OpenCV460/Binary/lib/cmake/opencv4)

    # simd
    set(XTENSOR_USE_XSIMD ON)
    set(xtl_DIR /media/tacom/fd1834d9-91ec-45dc-908b-eed1b326caaa/Envs/onnxruntime-openvino/xtensor/xtlBin/share/cmake/xtl)
    set(xsimd_DIR /media/tacom/fd1834d9-91ec-45dc-908b-eed1b326caaa/Envs/onnxruntime-openvino/xtensor/xsimdBin/share/cmake/xsimd)
    set(xtensor_DIR /media/tacom/fd1834d9-91ec-45dc-908b-eed1b326caaa/Envs/onnxruntime-openvino/xtensor/xtensorBin/share/cmake/xtensor)

    # onnxruntime
    set(onnxruntime_DIR /media/tacom/fd1834d9-91ec-45dc-908b-eed1b326caaa/Envs/onnxruntime-openvino/onnxruntimeBin)
    set(onnxruntime_INCLUDE ${onnxruntime_DIR}/include/onnxruntime)
    set(onnxruntime_LIBS
        ${onnxruntime_DIR}/lib/libonnxruntime.so
        ${onnxruntime_DIR}/lib/libonnxruntime_providers_openvino.so
        ${onnxruntime_DIR}/lib/libonnxruntime_providers_shared.so
    )

endif()

